package solucionessgh.View;


import javax.swing.ImageIcon;
import javax.swing.JButton;
import javax.swing.JTextField;
import javax.swing.JToolBar;
import solucionessgh.Moneda.MonedaController;

/**
 *
 * @author roderick
 */

public class ViewToolBar extends JToolBar{

    private JButton moneda ;
    private JTextField user;

    public ViewToolBar(){
        this.setOrientation(ViewToolBar.HORIZONTAL);        
        this.setRollover(true);        
        initComponents();
    }

    private void initComponents(){
        moneda = new JButton();
        moneda.setIcon(new ImageIcon(getClass().getResource("/solucionessgh/resources/tool_moneda.png")));
        moneda.setToolTipText("moneda");
        moneda.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                MonedaController moneda = new MonedaController();
                moneda.renderView();
            }
        });
        add(moneda);
        this.addSeparator();


        user = new JTextField("user");
        user.setEditable(false);        
        add(user);
        this.addSeparator();
    }
}

